package com.dragon.modules.yuegou.properties;

import org.springframework.boot.context.properties.ConfigurationProperties;

/**
 * 微信配置<br>
 * 配置小程序和公众号
 * 
 * @author liuwu
 *
 */
@ConfigurationProperties(prefix = "ysq.wechat")
public class WechatProperties {

	/**
	 * 悦购小程序
	 */
	private AppProperties xcx = new AppProperties();

	/**
	 * 悦商惠小程序
	 */
	private AppProperties merchantXcx = new AppProperties();

	/**
	 * 悦荷包小程序
	 */
	private AppProperties walletXcx = new AppProperties();

	/**
	 * 悦商圈公众号
	 */
	private AppProperties ysq = new AppProperties();

	public AppProperties getXcx() {
		return xcx;
	}

	public void setXcx(AppProperties xcx) {
		this.xcx = xcx;
	}

	public AppProperties getMerchantXcx() {
		return merchantXcx;
	}

	public void setMerchantXcx(AppProperties merchantXcx) {
		this.merchantXcx = merchantXcx;
	}

	public AppProperties getWalletXcx() {
		return walletXcx;
	}

	public void setWalletXcx(AppProperties walletXcx) {
		this.walletXcx = walletXcx;
	}

	public AppProperties getYsq() {
		return ysq;
	}

	public void setYsq(AppProperties ysq) {
		this.ysq = ysq;
	}

	/**
	 * 微信应用配置
	 * 
	 * @author liuwu
	 *
	 */
	public static class AppProperties {

		/**
		 * 小程序/公众号ID
		 */
		private String appid;

		/**
		 * 小程序/公众号密钥
		 */
		private String secret;

		private String mchid;

		private String key;

		private String certFile;

		private String certPassword;

		public String getAppid() {
			return appid;
		}

		public void setAppid(String appid) {
			this.appid = appid;
		}

		public String getSecret() {
			return secret;
		}

		public void setSecret(String secret) {
			this.secret = secret;
		}

		public String getMchid() {
			return mchid;
		}

		public void setMchid(String mchid) {
			this.mchid = mchid;
		}

		public String getKey() {
			return key;
		}

		public void setKey(String key) {
			this.key = key;
		}

		public String getCertFile() {
			return certFile;
		}

		public void setCertFile(String certFile) {
			this.certFile = certFile;
		}

		public String getCertPassword() {
			return certPassword;
		}

		public void setCertPassword(String certPassword) {
			this.certPassword = certPassword;
		}
	}

}
